package com.yx.changdao.web.config.quartz;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Configuration;

import java.util.Map;

/**
 * @Description: <br/>
 * 获取配置文件中的Quartz cron 表达式
 * <p>
 * <br/>
 * @Auther: zhangqi
 * @create 2019/11/21 9:02
 */
@EnableConfigurationProperties
@Configuration
@ConfigurationProperties(prefix = "quartz.job")
public class QuratzCronConfig {

    /**
     * key: 定时任务的全类名  value: cron表达式
     */
    private Map<String, String> crons;


    public void setCrons(Map<String, String> crons) {
        this.crons = crons;
    }

    public Map<String, String> getCrons() {
        return crons;
    }
}
